public class test {

   /* public static void print(int[] array,int len) {
        if(len == 1) {
            System.out.println(array[len-1]); //array[0]也可以
            return;
        }
        print(array,len-1);
        System.out.println(array[len-1]);
    }

    public static void main(String[] args) {
        int[] array = {1,2,3,4,5};

        print(array,array.length);
    }*/


   /* public static int sum1(int n) {
        if(n <=9) {
            return n;
        }
        int tem = n%10+sum1(n/10);
        return tem;

    }

    public static void main(String[] args) {
        System.out.println(sum1(213));
    }*/



   /* //求1+2+3+......+n
    public static void sum(int n) {
        if(n==1) {
            return 1;
        }
        int tmp = n+sum(n-1);
        return tmp;
    }

    public static void main3(String[] args) {
        System.out.println(sum(10));
    }


    //按顺序打印123的每一位 1  2 3
    public static int func1(int n) {
        if(n<=9) {
            System.out.println(n);
            return;
        }
        func1(n/10);
        System.out.println(n%10);
    }

    public static void main2(String[] args) {
      func1(123);
    }
*/

  /*  public static int func( int  n) {
        if(n ==1 ) {
            return 1;
        }

        int tmp = n * func(n-1);
             return tmp;
    }

    public static void main1(String[] args) {
        System.out.println( func(5));
    }*/
}
